/**
 *umi登录验证
 */
import { Redirect } from 'umi'
import {getToken} from '@/utils/status'
export default (props) => {
  if (getToken("token")) {
    return <div>{ props.children }</div>;
  } else {
    return <Redirect to="/login" />;
  }
}